<?php

namespace App\Models\Settings;

use App\Models\BaseModel;

class CodeValue extends BaseModel
{
    protected $table = 'settings__code_values';

    /**
     * 字段
     * @var array
     */
    protected $fillable = [
        'id',
        'value',
        'name',
        'code',
        'desc',
        'deleted_at',
        'updated_at',
        'created_at'
    ];

    public function codeInfo()
    {
        return $this->belongsTo(Code::class, 'code', 'code');
    }
}
